import { EntityBasis } from 'src/common/database/EntityBasis';
import { Entity, Column, PrimaryGeneratedColumn } from 'typeorm';

@Entity('employment') // 根据接口名称设置实际表名
export class Employment extends EntityBasis {
  @PrimaryGeneratedColumn({ comment: '主键ID' })
  id?: number;

  @Column({
    type: 'varchar',
    length: 200,
    nullable: false,
    comment: '新闻标题',
  })
  biaoti: string;

  @Column({
    type: 'varchar',
    length: 100,
    nullable: false,
    comment: '新闻类别',
  })
  leibie: string;

  @Column({
    type: 'int',
    default: 0,
    comment: '点击次数统计',
  })
  dianjilv: number;

  @Column({
    type: 'text',
    nullable: true,
    comment: '新闻详细内容',
  })
  neirong?: string;
}
